﻿using UnityEngine;
using System.Collections;

[System.Serializable]
public class PlayerData
{
	public static int highScore = 0;


	public static void setHighScore(int currentScore)
	{
		if(currentScore > highScore)
		{
			highScore = currentScore;
			PlayerPrefs.SetInt("highScore",highScore);
			PlayerPrefs.Save();
		}
	}

	public static void initPlayerData()
	{
		highScore = PlayerPrefs.GetInt("highScore");
	}

}
